﻿using WeiBeeCommon.Core;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;

namespace TestProject1
{
    
    
    /// <summary>
    ///This is a test class for UtilityTest and is intended
    ///to contain all UtilityTest Unit Tests
    ///</summary>
    [TestClass()]
    public class UtilityTest
    {


        private TestContext testContextInstance;

        /// <summary>
        ///Gets or sets the test context which provides
        ///information about and functionality for the current test run.
        ///</summary>
        public TestContext TestContext
        {
            get
            {
                return testContextInstance;
            }
            set
            {
                testContextInstance = value;
            }
        }

        #region Additional test attributes
        // 
        //You can use the following additional attributes as you write your tests:
        //
        //Use ClassInitialize to run code before running the first test in the class
        //[ClassInitialize()]
        //public static void MyClassInitialize(TestContext testContext)
        //{
        //}
        //
        //Use ClassCleanup to run code after all tests in a class have run
        //[ClassCleanup()]
        //public static void MyClassCleanup()
        //{
        //}
        //
        //Use TestInitialize to run code before running each test
        //[TestInitialize()]
        //public void MyTestInitialize()
        //{
        //}
        //
        //Use TestCleanup to run code after each test has run
        //[TestCleanup()]
        //public void MyTestCleanup()
        //{
        //}
        //
        #endregion


        /// <summary>
        ///A test for WebRequestUseAsyncEnumerator
        ///</summary>
        [TestMethod()]
        public void WebRequestUseAsyncEnumeratorTest()
        {
            Method method = Method.GET;// new Method(); // TODO: Initialize to an appropriate value
            string url = "http://api.t.sina.com.cn/account/verify_credentials.xml?oauth_consumer_key=3587646579&oauth_nonce=3636566&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1312015003&oauth_token=1c1b8e4800c0cc920df3cce7e24b3e66&oauth_version=1.0&oauth_signature=8Krw5M3Q8Pj75QoZ%2fx3%2f7D49Dl4%3d";//string.Empty; // TODO: Initialize to an appropriate value
            string postData = string.Empty; // TODO: Initialize to an appropriate value
            string expected = string.Empty; // TODO: Initialize to an appropriate value
            string actual;
            actual = Utility.WebRequestUseAsyncEnumerator(method, url, postData);
            Assert.AreEqual(expected, actual);
        }
    }
}
